package com.hup.utils.swing.view.commons;

import com.hup.utils.swing.customView.FileChooserPanel;
import com.hup.utils.swing.customView.ImageButton;
import com.hup.utils.swing.customView.ImageButton.TextPosition;
import com.hup.utils.swing.customView.KeyboardText;
import com.hup.utils.swing.customView.ScreenScaleComboBox;
import com.hup.utils.swing.customView.VerticalCheckBox;
import com.hup.utils.swing.customView.spinner.IntSpinner;

import javax.swing.ImageIcon;
import javax.swing.JButton;
import javax.swing.JCheckBox;
import javax.swing.JComponent;
import javax.swing.JLabel;
import javax.swing.JPanel;
import java.awt.GridBagConstraints;
import java.awt.GridBagLayout;

/**
 * @author hugan
 * @date 2020/4/4
 */
public class CommonsTestForm {
    public JPanel root;
    public JButton btnScreenShot;
    public JButton btnColorPanel;
    public ImageButton btnPipet;
    public VerticalCheckBox cbWrap;
    public JLabel labScreenShot;
    public FileChooserPanel fileChooser;

    public CommonsTestForm() {
        $$$setupUI$$$();
        fileChooser.addMiddle(new JCheckBox("aad"));
    }

    /**
     * Method generated by IntelliJ IDEA GUI Designer
     * >>> IMPORTANT!! <<<
     * DO NOT edit this method OR call it in your code!
     *
     * @noinspection ALL
     */
    private void $$$setupUI$$$() {
        root = new JPanel();
        root.setLayout(new GridBagLayout());
        final JPanel panel1 = new JPanel();
        panel1.setLayout(new GridBagLayout());
        GridBagConstraints gbc;
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 2;
        gbc.fill = GridBagConstraints.BOTH;
        root.add(panel1, gbc);
        fileChooser = new FileChooserPanel();
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 0;
        gbc.anchor = GridBagConstraints.WEST;
        panel1.add(fileChooser, gbc);
        final JPanel spacer1 = new JPanel();
        gbc = new GridBagConstraints();
        gbc.gridx = 2;
        gbc.gridy = 0;
        gbc.weightx = 1.0;
        gbc.fill = GridBagConstraints.HORIZONTAL;
        panel1.add(spacer1, gbc);
        final JLabel label1 = new JLabel();
        label1.setText("Label");
        gbc = new GridBagConstraints();
        gbc.gridx = 1;
        gbc.gridy = 0;
        gbc.anchor = GridBagConstraints.WEST;
        panel1.add(label1, gbc);
        final JPanel panel2 = new JPanel();
        panel2.setLayout(new GridBagLayout());
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 0;
        gbc.weightx = 1.0;
        gbc.fill = GridBagConstraints.BOTH;
        root.add(panel2, gbc);
        cbWrap = new VerticalCheckBox();
        cbWrap.setWarpAbleText("隐藏\n浏览器");
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 0;
        panel2.add(cbWrap, gbc);
        final JPanel spacer2 = new JPanel();
        gbc = new GridBagConstraints();
        gbc.gridx = 4;
        gbc.gridy = 0;
        gbc.weightx = 1.0;
        gbc.fill = GridBagConstraints.HORIZONTAL;
        panel2.add(spacer2, gbc);
        final JPanel spacer3 = new JPanel();
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 1;
        gbc.fill = GridBagConstraints.VERTICAL;
        panel2.add(spacer3, gbc);
        btnPipet = new ImageButton();
        btnPipet.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_pipet.gif")));
        gbc = new GridBagConstraints();
        gbc.gridx = 1;
        gbc.gridy = 0;
        gbc.fill = GridBagConstraints.BOTH;
        panel2.add(btnPipet, gbc);
        btnScreenShot = new JButton();
        btnScreenShot.setText("screenShot");
        gbc = new GridBagConstraints();
        gbc.gridx = 2;
        gbc.gridy = 0;
        gbc.fill = GridBagConstraints.HORIZONTAL;
        panel2.add(btnScreenShot, gbc);
        btnColorPanel = new JButton();
        btnColorPanel.setText("colorPanel");
        gbc = new GridBagConstraints();
        gbc.gridx = 3;
        gbc.gridy = 0;
        gbc.fill = GridBagConstraints.HORIZONTAL;
        panel2.add(btnColorPanel, gbc);
        final ScreenScaleComboBox screenScaleComboBox1 = new ScreenScaleComboBox();
        gbc = new GridBagConstraints();
        gbc.gridx = 2;
        gbc.gridy = 1;
        gbc.fill = GridBagConstraints.BOTH;
        panel2.add(screenScaleComboBox1, gbc);
        final IntSpinner intSpinner1 = new IntSpinner();
        gbc = new GridBagConstraints();
        gbc.gridx = 2;
        gbc.gridy = 2;
        panel2.add(intSpinner1, gbc);
        final JPanel panel3 = new JPanel();
        panel3.setLayout(new GridBagLayout());
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 1;
        gbc.weightx = 1.0;
        gbc.weighty = 1.0;
        gbc.fill = GridBagConstraints.BOTH;
        root.add(panel3, gbc);
        final ImageButton imageButton1 = new ImageButton();
        imageButton1.setCheckbox(true);
        imageButton1.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_pipet.gif")));
        imageButton1.setPadding(15);
        imageButton1.setSelected(true);
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 0;
        gbc.gridwidth = 2;
        gbc.gridheight = 2;
        gbc.weightx = 1.0;
        gbc.weighty = 0.5;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton1, gbc);
        final ImageButton imageButton2 = new ImageButton();
        imageButton2.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_add.gif")));
        gbc = new GridBagConstraints();
        gbc.gridx = 4;
        gbc.gridy = 0;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton2, gbc);
        final ImageButton imageButton3 = new ImageButton();
        imageButton3.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_add.gif")));
        gbc = new GridBagConstraints();
        gbc.gridx = 4;
        gbc.gridy = 1;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton3, gbc);
        final ImageButton imageButton4 = new ImageButton();
        imageButton4.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_add.gif")));
        imageButton4.setText("啊j");
        gbc = new GridBagConstraints();
        gbc.gridx = 3;
        gbc.gridy = 0;
        gbc.gridheight = 2;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton4, gbc);
        final ImageButton imageButton5 = new ImageButton();
        imageButton5.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_add.gif")));
        imageButton5.setPadding(10);
        imageButton5.setText("顶Aj");
        imageButton5.setTextPosition(TextPosition.TOP);
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 2;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton5, gbc);
        final ImageButton imageButton6 = new ImageButton();
        imageButton6.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_add.gif")));
        imageButton6.setPadding(0);
        imageButton6.setText("底Aj");
        gbc = new GridBagConstraints();
        gbc.gridx = 1;
        gbc.gridy = 2;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton6, gbc);
        final ImageButton imageButton7 = new ImageButton();
        imageButton7.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_add.gif")));
        imageButton7.setPadding(10);
        imageButton7.setText("顶Aj");
        imageButton7.setTextPosition(TextPosition.TOP);
        gbc = new GridBagConstraints();
        gbc.gridx = 2;
        gbc.gridy = 1;
        gbc.weightx = 1.0;
        gbc.weighty = 0.5;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton7, gbc);
        final ImageButton imageButton8 = new ImageButton();
        imageButton8.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_add.gif")));
        imageButton8.setPadding(10);
        imageButton8.setText("底Aj p=10");
        gbc = new GridBagConstraints();
        gbc.gridx = 2;
        gbc.gridy = 2;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton8, gbc);
        final ImageButton imageButton9 = new ImageButton();
        imageButton9.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_add.gif")));
        imageButton9.setPadding(10);
        imageButton9.setText("底Aj p=10");
        gbc = new GridBagConstraints();
        gbc.gridx = 4;
        gbc.gridy = 2;
        panel3.add(imageButton9, gbc);
        final ImageButton imageButton10 = new ImageButton();
        imageButton10.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_pipet.gif")));
        imageButton10.setText("右j");
        imageButton10.setTextPosition(TextPosition.RIGHT);
        gbc = new GridBagConstraints();
        gbc.gridx = 6;
        gbc.gridy = 1;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton10, gbc);
        final ImageButton imageButton11 = new ImageButton();
        imageButton11.setEnabled(false);
        imageButton11.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_pipet.gif")));
        imageButton11.setText("dis");
        imageButton11.setTextPosition(TextPosition.RIGHT);
        gbc = new GridBagConstraints();
        gbc.gridx = 5;
        gbc.gridy = 1;
        gbc.fill = GridBagConstraints.BOTH;
        panel3.add(imageButton11, gbc);
        final JPanel panel4 = new JPanel();
        panel4.setLayout(new GridBagLayout());
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 3;
        gbc.fill = GridBagConstraints.BOTH;
        root.add(panel4, gbc);
        final ImageButton imageButton12 = new ImageButton();
        imageButton12.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_pipet.gif")));
        imageButton12.setText("左j");
        imageButton12.setTextPosition(TextPosition.LEFT);
        gbc = new GridBagConstraints();
        gbc.gridx = 1;
        gbc.gridy = 1;
        panel4.add(imageButton12, gbc);
        final ImageButton imageButton13 = new ImageButton();
        imageButton13.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_pipet.gif")));
        imageButton13.setText("左j");
        imageButton13.setTextPosition(TextPosition.LEFT);
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 1;
        gbc.weightx = 1.0;
        gbc.fill = GridBagConstraints.BOTH;
        panel4.add(imageButton13, gbc);
        final ImageButton imageButton14 = new ImageButton();
        imageButton14.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_pipet.gif")));
        imageButton14.setPadding(0);
        imageButton14.setText("右j");
        imageButton14.setTextPosition(TextPosition.RIGHT);
        gbc = new GridBagConstraints();
        gbc.gridx = 2;
        gbc.gridy = 1;
        panel4.add(imageButton14, gbc);
        final ImageButton imageButton15 = new ImageButton();
        imageButton15.setIcon(new ImageIcon(getClass().getResource("/static/icon/icon_pipet.gif")));
        imageButton15.setText("右j");
        imageButton15.setTextPosition(TextPosition.RIGHT);
        gbc = new GridBagConstraints();
        gbc.gridx = 3;
        gbc.gridy = 1;
        gbc.weightx = 1.0;
        gbc.fill = GridBagConstraints.VERTICAL;
        panel4.add(imageButton15, gbc);
        final KeyboardText keyboardText1 = new KeyboardText();
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 0;
        gbc.gridwidth = 4;
        gbc.fill = GridBagConstraints.BOTH;
        panel4.add(keyboardText1, gbc);
        labScreenShot = new JLabel();
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 4;
        gbc.weightx = 1.0;
        gbc.weighty = 1.0;
        gbc.fill = GridBagConstraints.BOTH;
        root.add(labScreenShot, gbc);
    }

    /**
     * @noinspection ALL
     */
    public JComponent $$$getRootComponent$$$() { return root; }

}
